import 'package:flutter/material.dart';
import 'package:flutter/widgets.dart';
import 'dart:async';

class SingleScreen extends StatefulWidget {
  @override
  _SingleScreenState createState() => _SingleScreenState();
}

class _SingleScreenState extends State<SingleScreen> {
  @override
  Widget build(BuildContext context) {
    return Container(
      color: Colors.white,
      child: new Image(
        image: new AssetImage("images/close.png"),
        width: 25,
        height: 25,
      ),
    );
  }

  void initState() {
    super.initState();
    conutDown();
  }

  void conutDown() {
    var _duration = Duration(seconds: 3);
    Future.delayed(_duration, BottomNavigationWidget);
  }

  void BottomNavigationWidget() {
    Navigator.of(context).pushReplacementNamed('/BottomNavigationWidget');
  }
}